package com.nineclock.system.feign;

import com.nineclock.common.entity.Result;
import com.nineclock.system.dto.SysUserDTO;
import org.springframework.cloud.openfeign.FeignClient;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestParam;

@FeignClient("sys-service") // 被调用的微服务名称
public interface SysUserFeign {

    /**
     * 根据用户名/手机号查询用户信息
     * @param username 用户名/手机号
     * @return
     */
    @GetMapping("user/query")
    public Result<SysUserDTO> queryUser(@RequestParam String username);
}
